package com.hxzy.service.impl;

import com.hxzy.entity.UmsPermission;
import com.hxzy.mapper.UmsPermissionMapper;
import com.hxzy.service.UmsPermissionService;
import com.hxzy.util.MybatisUtil;
import org.apache.ibatis.session.SqlSession;

public class UmsPermissionServiceImpl implements UmsPermissionService {
    @Override
    public UmsPermission selectByPrimaryKey(Long id) {
        UmsPermission umsPermission=null;
        try(SqlSession session = MybatisUtil.getSqlSessionFactory().openSession()) {
            UmsPermissionMapper mapper=session.getMapper(UmsPermissionMapper.class);
           umsPermission= mapper.selectByPrimaryKey(id);
        }
        return umsPermission;
    }
}
